<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<jsp:include   page="common/header.jsp" flush="true">
    <jsp:param name="title" value="评估记录" /> 
</jsp:include>
<jsp:include   page="common/left.jsp" flush="true"/> 

	<!-- 右侧 -->
	<div class="record-page">
		<div class="container-fluid">
			<div class="row">
				<div class="col-lg-12">
					<div class="panel">
						<div class="panel-heading">
							<div class="row">
								<span class="record-heading-icon"></span> <span class="text">评估记录</span>
							</div>
						</div>
						<div class="panel-body">
							<div class="panel-body-title clearfix">
								<div class="left fl">
									<form action="${basePath }/wxUserdetailAction_newFindlist"
										method="post">
										<div class="check-wrapper">
											<div class="record-check-name">
												<input type="radio" name="check-answer" /><span>按罪名查找</span>
												<select name="chargetypeStr" id="">
													<option value="" >----请选择----</option>
													<c:forEach items="${chargetypes }" var="chargetype"
														varStatus="st">
														<c:if test="${st.index gt 0 }">
															<option value="${st.index }"
																<c:if test="${st.index == chargetypeStr }">selected="selected"</c:if>>${chargetype }</option>
														</c:if>
													</c:forEach>
												</select>
											</div>
											<div class="record-check-id">
												<input type="radio" name="check-answer" /><span>按案件名称查找</span>
												<input type="text" name="chargenameStr"
													value="${chargenameStr}" placeholder="请输入案件名称" />
											</div>
<!-- 											<div class="record-check-flag"> -->
<!-- 												<input type="radio" name="check-answer" /><span>是否羁押</span> -->
<!-- 												<select name="totalscoreStr" id=""> -->
<!-- 													<option value="" -->
<%-- 														<c:if test="${totalscoreStr eq '' }">selected="selected"</c:if>>所有</option> --%>
<!-- 													<option value="1" -->
<%-- 														<c:if test="${totalscoreStr eq '1'}">selected="selected"</c:if>>是</option> --%>
<!-- 													<option value="-1" -->
<%-- 														<c:if test="${totalscoreStr eq '-1'}">selected="selected"</c:if>>否</option> --%>
<!-- 												</select> -->
<!-- 											</div> -->
											<shiro:hasPermission name="wxUserdetail-save">
											<button class="record-title-search"></button>
											</shiro:hasPermission>
										</div>
									</form>
								</div>
								<div class="right fr">
									<shiro:hasPermission name="wxUserdetail-list">
									<a href="${basePath }/wxUserdetailAction_toAdd" class="record-add-btn"></a>
									</shiro:hasPermission>
								</div>
							</div>
							<div class="row">
								<div class="col-lg-6">
									<div class="table-responsive">
										<form action="">
											<table class="table table-bordered table-hover">
												<thead>
													<tr>
														<th>序号</th>
														<th>罪名</th>
														<th>案件名称</th>
														<th>姓名</th>
														<th>总分值</th>
														<th>是否羁押</th>
														<th>操作</th>
													</tr>
												</thead>
												<tbody>
													<c:forEach items="${list }" var="list" varStatus="status">
														<tr>
															<td>${status.index+1}</td>
															<td><c:forEach items="${chargetypes }" var="chargetype"
																	varStatus="st">
																	<c:if
																		test="${list.chargetype eq st.index }">${chargetype }</c:if>
																</c:forEach></td>
															<td>${list.chargename }</td>
															<td>${list.wxUserlist_fordetail.truename }</td>
															<td>${list.wxEvalresult_fordetail.totalscore }</td>
															<td>
																<c:choose>
																	<c:when test="${list.wxEvalresult_fordetail.totalscore > -6}">是</c:when>
																	<c:otherwise>否</c:otherwise>
																</c:choose>
															</td>
															<td>
															<!-- 编辑按钮 -->
	<!-- 															<span class="glyphicon glyphicon-edit" -->
	<!-- 																aria-hidden="true" id="crime-edit"></span> -->
															<!-- 删除按钮 -->
															<shiro:hasPermission name="wxUserdetail-delete">
																 <a href="javascript:void(0)" id="crime-delete" onclick="delUsertail('${list.id}')">
																 	<span
																	class="glyphicon glyphicon-remove-circle"
																	aria-hidden="true"></span></a>
															</shiro:hasPermission>		
															</td>
															
														</tr>
													</c:forEach>
												</tbody>
											</table>
										</form>
										<!-- 分页 -->
										<div class="page">
											<div class="left fl">
												<a
													href="${basePath }/wxUserdetailAction_newFindlist?currentPage=1">首页</a>
												<c:forEach begin="1" end="${pageBean.totalPage }"
													varStatus="status">
													<c:if test="${status.count == pageBean.currentPage}">
														<a
															href="${basePath }/wxUserdetailAction_newFindlist?currentPage=${status.count }"
															class="active">${status.count }</a>
													</c:if>
													<c:if test="${status.count != pageBean.currentPage}">
														<a
															href="${basePath }/wxUserdetailAction_newFindlist?currentPage=${status.count }">${status.count }</a>
													</c:if>
												</c:forEach>
												<c:if test="${pageBean.currentPage < pageBean.totalPage}">
													<a
														href="${basePath }/wxUserdetailAction_newFindlist?currentPage=${pageBean.currentPage +1}">下一页</a>
												</c:if>
												<c:if test="${pageBean.currentPage >= pageBean.totalPage}">
													<a href="javascript:;">下一页</a>
												</c:if>

												<a
													href="${basePath }/wxUserdetailAction_newFindlist?currentPage=${pageBean.totalPage }">尾页</a>
												<input type="hidden" id="totalPage"
													value="${pageBean.totalPage }"> <span>跳至</span> <input
													type="text" id="pageGO" /> <a href="javascript:;"
													id="paegLinkGo1">GO</a>
											</div>
											<div class="right fr">
												<span class="now-num">当前第<b>${pageBean.currentPage }</b>页
												</span> <span class="toggle-num">共<b>${pageBean.totalPage }</b>页
												</span>
											</div>
										</div>

										<script type="text/javascript">
										       	$(document).on('click', '#paegLinkGo1', function() {
										       		var page = $('#pageGO').val();
										       		var totalPage = $('#totalPage').val()
										       		if(page >0 && page <= totalPage){
										       		window.location.href = "${basePath }/wxUserdetailAction_newFindlist?currentPage="+page;
										       		}else{
										       			return false;
										       		}
										       	})
										    </script>
										<!-- 分页end	 -->
									</div>
								</div>
							</div>
						</div>
					</div>
				</div>
			</div>
		</div>

    </div>
<script type="text/javascript" src="${basePath }/page/js/record.js"></script>
<jsp:include   page="common/bottom.jsp" flush="true"/> 
